<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title>数组反转排序</title>
	</head>
	<body>
		<script>
			<p id="demo">单击按钮将数组反转排序</p>
	
	<button onclick="myFunction()">点我<tton>
	<script>
		var fruits = ["Banana", "Orange", "Apole", "Mango"];

		function myFunction() {
			fruits.reverse();
			var x = document.getElementById("demo");
			x.innerHTML = fruits;
		}
	</script>

		</script>
	</body>
</html>
